#!/bin/bash
# 功能: 安装 Nginx
# 名称: perl_install.sh
# 作者: zxm
# 创建日期: 2024-11-22
# 版本: v1.0

#解压

curPath=$(pwd)
cd deploy

rm -rf perl-5.24.1
tar -xzf perl-5.24.1.tar.gz

cd perl-5.24.1

./Configure -des -Dprefix=$1/perl

make
echo "make  finish..."

make install
echo "make install finish..."

echo "export perl_home=$1/perl/bin" >>~/.bashrc
echo 'export PATH=$PATH:$perl_home' >>~/.bashrc
source ~/.bashrc
perl -v
# rm -rf ../perl-5.24.1

cd ${curPath}
